<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.6"/>
<title>3dchess: AbstractState Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">3dchess
   </div>
   <div id="projectbrief">Basic chess application with OpenGL graphics and AI</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.6 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Enumerator</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="class_abstract_state-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">AbstractState Class Reference<span class="mlabels"><span class="mlabel">abstract</span></span></div>  </div>
</div><!--header-->
<div class="contents">

<p>Interface for modelling a game state.  
 <a href="class_abstract_state.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="_abstract_state_8h_source.html">AbstractState.h</a>&gt;</code></p>
<div class="dynheader">
Inheritance diagram for AbstractState:</div>
<div class="dyncontent">
 <div class="center">
  <img src="class_abstract_state.png" usemap="#AbstractState_map" alt=""/>
  <map id="AbstractState_map" name="AbstractState_map">
<area href="class_game_play.html" title="Class which holds the state GamePlay. " alt="GamePlay" shape="rect" coords="0,56,112,80"/>
<area href="class_menu_game_mode.html" title="Class which holds the state GameMode. " alt="MenuGameMode" shape="rect" coords="122,56,234,80"/>
<area href="class_menu_load_game.html" title="Class which holds the state LoadGame. " alt="MenuLoadGame" shape="rect" coords="244,56,356,80"/>
<area href="class_menu_main.html" title="Class which holds the state MenuMain. " alt="MenuMain" shape="rect" coords="366,56,478,80"/>
<area href="class_menu_options.html" title="Class which holds the state MenuOption. " alt="MenuOptions" shape="rect" coords="488,56,600,80"/>
<area href="class_menu_player_color.html" title="Class which holds the state PlayerColor. " alt="MenuPlayerColor" shape="rect" coords="610,56,722,80"/>
</map>
 </div></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a6c54a7c162cd2bce6ddb83d5eef8ec4c"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_abstract_state.html#a6c54a7c162cd2bce6ddb83d5eef8ec4c">enter</a> ()=0</td></tr>
<tr class="memdesc:a6c54a7c162cd2bce6ddb83d5eef8ec4c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enters the state for the first time.  <a href="#a6c54a7c162cd2bce6ddb83d5eef8ec4c">More...</a><br/></td></tr>
<tr class="separator:a6c54a7c162cd2bce6ddb83d5eef8ec4c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afdda3d13dbad7a41987c9e05b705cd9e"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="class_abstract_state.html">AbstractState</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_abstract_state.html#afdda3d13dbad7a41987c9e05b705cd9e">run</a> ()=0</td></tr>
<tr class="memdesc:afdda3d13dbad7a41987c9e05b705cd9e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Runs the current state and does all the work.  <a href="#afdda3d13dbad7a41987c9e05b705cd9e">More...</a><br/></td></tr>
<tr class="separator:afdda3d13dbad7a41987c9e05b705cd9e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a12e500a1e81bcb710d6b50aa99695e3a"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_abstract_state.html#a12e500a1e81bcb710d6b50aa99695e3a">exit</a> ()=0</td></tr>
<tr class="memdesc:a12e500a1e81bcb710d6b50aa99695e3a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Exits the current state and cleans up all allocated resources.  <a href="#a12e500a1e81bcb710d6b50aa99695e3a">More...</a><br/></td></tr>
<tr class="separator:a12e500a1e81bcb710d6b50aa99695e3a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a849114d39ed3aeb7be8c137dcd6efd67"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a849114d39ed3aeb7be8c137dcd6efd67"></a>
virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_abstract_state.html#a849114d39ed3aeb7be8c137dcd6efd67">draw</a> ()=0</td></tr>
<tr class="memdesc:a849114d39ed3aeb7be8c137dcd6efd67"><td class="mdescLeft">&#160;</td><td class="mdescRight">Draws something state related stuff on the screen. <br/></td></tr>
<tr class="separator:a849114d39ed3aeb7be8c137dcd6efd67"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Interface for modelling a game state. </p>
<dl class="section note"><dt>Note</dt><dd>To <a class="el" href="class_abstract_state.html#afdda3d13dbad7a41987c9e05b705cd9e" title="Runs the current state and does all the work. ">run()</a> a state, first <a class="el" href="class_abstract_state.html#a6c54a7c162cd2bce6ddb83d5eef8ec4c" title="Enters the state for the first time. ">enter()</a> the state. </dd></dl>
</div><h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="a6c54a7c162cd2bce6ddb83d5eef8ec4c"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void AbstractState::enter </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">pure virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Enters the state for the first time. </p>
<p>This will setup all the state related stuff. </p>
<dl class="section note"><dt>Note</dt><dd>To <a class="el" href="class_abstract_state.html#afdda3d13dbad7a41987c9e05b705cd9e" title="Runs the current state and does all the work. ">run()</a> the current state, first <a class="el" href="class_abstract_state.html#a6c54a7c162cd2bce6ddb83d5eef8ec4c" title="Enters the state for the first time. ">enter()</a> it. </dd></dl>

<p>Implemented in <a class="el" href="class_game_play.html#a265e1c47781f3ab890a648c9811738d7">GamePlay</a>, <a class="el" href="class_menu_game_mode.html#afb10452c6e34d28a6a51b0580e42a0bf">MenuGameMode</a>, <a class="el" href="class_menu_load_game.html#a1d1319eb1e74af8c48fb66f918f7c67e">MenuLoadGame</a>, <a class="el" href="class_menu_options.html#a8577426043149d0f2b1765c1e321c7c9">MenuOptions</a>, <a class="el" href="class_menu_main.html#ad70abaa1eeed0c16fb756fc183847076">MenuMain</a>, and <a class="el" href="class_menu_player_color.html#a99e851103d0c0d7bde839520fe39aaa5">MenuPlayerColor</a>.</p>

</div>
</div>
<a class="anchor" id="a12e500a1e81bcb710d6b50aa99695e3a"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual void AbstractState::exit </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">pure virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Exits the current state and cleans up all allocated resources. </p>
<dl class="section note"><dt>Note</dt><dd>This is the last method to call, before the object is deleted. </dd></dl>

<p>Implemented in <a class="el" href="class_game_play.html#af635ce486e5bc9b3bdf21241f6737000">GamePlay</a>, <a class="el" href="class_menu_game_mode.html#aa6bbd8d91782e68c93407e5763e97934">MenuGameMode</a>, <a class="el" href="class_menu_load_game.html#a734f37cb1935f42015869f352f15be97">MenuLoadGame</a>, <a class="el" href="class_menu_options.html#a24cdc138bd33a3029098c9553f68bcde">MenuOptions</a>, <a class="el" href="class_menu_main.html#af78b171ee4466a53b3fc36d11d486890">MenuMain</a>, and <a class="el" href="class_menu_player_color.html#aafdef161a30894d1b9f673c06121499b">MenuPlayerColor</a>.</p>

</div>
</div>
<a class="anchor" id="afdda3d13dbad7a41987c9e05b705cd9e"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="class_abstract_state.html">AbstractState</a>* AbstractState::run </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">pure virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Runs the current state and does all the work. </p>
<dl class="section return"><dt>Returns</dt><dd>AbstractState* the state which should be run after this state. A nullptr if the game should be exited. </dd></dl>

<p>Implemented in <a class="el" href="class_game_play.html#aa488735535fde3fa3ac41ee94112141e">GamePlay</a>, <a class="el" href="class_menu_game_mode.html#aefba7f005740cda5041bd0bb07bdc2b4">MenuGameMode</a>, <a class="el" href="class_menu_load_game.html#a64e0d14e82a98dc7b4b6c87e5c979487">MenuLoadGame</a>, <a class="el" href="class_menu_options.html#a25bd2a4751a79948ba536de7bf15c8a2">MenuOptions</a>, <a class="el" href="class_menu_main.html#af49651e8c43fc8ad8b37477db0301fae">MenuMain</a>, and <a class="el" href="class_menu_player_color.html#adac3c1c8f9d1fc8179f442cc78b35ef4">MenuPlayerColor</a>.</p>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li>S:/dev/3dchess/src/gui/interface/<a class="el" href="_abstract_state_8h_source.html">AbstractState.h</a></li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Sun Mar 9 2014 23:12:56 for 3dchess by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.6
</small></address>
</body>
</html>
